/* 重置和全局样式 */
html,
body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen,
    Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  font-size: 16px;
  color: #333;
  background-color: #f5f7fa;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  overflow-x: hidden;
}

* {
  box-sizing: border-box;
}

/* 滚动条样式 */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

::-webkit-scrollbar-thumb {
  background: #ddd;
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: #ccc;
}

/* 页面过渡动画 */
.page-enter-active,
.page-leave-active {
  transition: opacity 0.3s, transform 0.3s;
}

.page-enter-from,
.page-leave-to {
  opacity: 0;
  transform: translateY(10px);
}

/* 内容容器 */
.content-container {
  padding: 16px;
}

/* 主标题 */
.page-title {
  margin: 0 0 20px;
  font-size: 20px;
  font-weight: 600;
  color: #323233;
}

/* 卡片样式 */
.card {
  background: #fff;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 16px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

/* 按钮组 */
.button-group {
  display: flex;
  justify-content: space-between;
  margin-top: 16px;
}

/* 加载中样式 */
.loading-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100px;
}

/* 空状态 */
.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: #969799;
}

.empty-state-icon {
  font-size: 48px;
  margin-bottom: 16px;
}

.empty-state-text {
  font-size: 14px;
}

/* 底部固定操作栏 */
.action-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #fff;
  padding: 10px 16px;
  box-shadow: 0 -1px 3px rgba(0, 0, 0, 0.05);
  z-index: 10;
}

/* 考试相关样式 */
.question-content {
  font-size: 16px;
  margin-bottom: 16px;
}

.options-list {
  margin-bottom: 20px;
}

.option-item {
  margin-bottom: 12px;
}

.question-navigation {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.question-nav-item {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background: #f2f3f5;
  font-size: 14px;
  color: #323233;
}

.question-nav-item.answered {
  background: #1989fa;
  color: #fff;
}

.question-nav-item.current {
  border: 2px solid #1989fa;
}

/* 考试计时器 */
.exam-timer {
  background: #fff;
  padding: 8px 16px;
  text-align: center;
  position: sticky;
  top: 0;
  z-index: 2;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.exam-timer.warning {
  color: #ee0a24;
  animation: timer-pulse 1s infinite;
}

@keyframes timer-pulse {
  0% { opacity: 1; }
  50% { opacity: 0.7; }
  100% { opacity: 1; }
}

/* 用户信息卡片 */
.user-info-card {
  display: flex;
  align-items: center;
  padding: 16px;
  background: #fff;
  border-radius: 8px;
  margin-bottom: 16px;
}

.user-avatar {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  margin-right: 16px;
  background: #f0f0f0;
  overflow: hidden;
}

.user-details {
  flex: 1;
}

.user-name {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 4px;
}

.user-phone {
  font-size: 14px;
  color: #969799;
}

/* 考试结果 */
.score-card {
  text-align: center;
  padding: 24px 16px;
}

.score-value {
  font-size: 40px;
  font-weight: 700;
  color: #1989fa;
  margin-bottom: 8px;
}

.score-label {
  font-size: 14px;
  color: #969799;
}

.result-stats {
  display: flex;
  justify-content: space-around;
  margin: 16px 0;
}

.stat-item {
  text-align: center;
}

.stat-value {
  font-size: 18px;
  font-weight: 500;
  color: #323233;
}

.stat-label {
  font-size: 12px;
  color: #969799;
}

/* 历史记录卡片 */
.history-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  background: #fff;
  border-radius: 8px;
  margin-bottom: 12px;
}

.history-title {
  font-size: 16px;
  font-weight: 500;
  margin-bottom: 4px;
}

.history-time {
  font-size: 12px;
  color: #969799;
}

.history-score {
  font-size: 20px;
  font-weight: 600;
  color: #1989fa;
}

/* 表单样式优化 */
.form-group {
  margin-bottom: 16px;
}

.form-label {
  font-size: 14px;
  color: #646566;
  margin-bottom: 8px;
  display: block;
}

/* 颜色 */
.color-primary {
  color: #1989fa;
}

.color-success {
  color: #07c160;
}

.color-warning {
  color: #ff976a;
}

.color-danger {
  color: #ee0a24;
}
